home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CD School House 9
/
CD School House 9.0 - Wayzata Technology (1994).iso
/
pc
/
dos
/
math
/
eebond
/
sdfcvt.exe
/
COMMAND.SDF
next >
Wrap
Text File
|
1993-04-08
|
6KB
|
156 lines
(C) Copyright 1991-1993 by Alan J. Avery. All Rights Reserved.
Sample command file for SDF.EXE, the program that lets the user convert
delimited ASCII files without programming and without using a spreadsheet,
database, word processor or other major application program.
The basic format of this file is simple:
Start comments with a space, tab, asterisk or semicolon in column 1.
Blank lines will be ignored, as will anything that is not recognized
to be a command.
Commands MUST start in column 1 (!) and can be in UPPER or lower case.
If a command requires a value associated with it, this value must
begin in column 21 or later!
Some commands pertain to processing the entire file, others pertain to
processing a particular field. File commands are listed first in this
sample command file, field commands follow.
ONLY - Force the fields specified below to be kept in the file that is
created, and no others.
Only
REORDER - Force the fields to be kept in the order encountered in this file.
Note! If you use REORDER, then ONLY is assumed as well.
Reorder
INPUT FILE - File to be processed.
Input File FILE1.PRN
OUTPUT FILE - File to be created. The extension is ignore for PARADOX files.
Output File FILE2.DBF
FIELDS PER LINE - Maximum # of fields to expect per line. Keep this small.
Default is 500.
Fields Per Line 400
SURROUNDED BY - Character that surrounds fields in the file (if any).
Surrounded By "
DELIMITED BY - Character that delimits fields in the file.
Delimited By ,
FILL WITH - Character used to fill unused space in the output file.
(Specify as an ASCII number from 0-255. Default is 32 [Space])
(Can also be specified as a character by simply entering the
character in column 21, if it is not a control character.)
Fill With 0
LINE START - Start processing at this line.
Line Start 1
LINE END - End processing at this line.
Line End 200
MAXIMUM LENGTH - Maximum length for any field.
Maximum Length
MINIMUM LENGTH - Minimum length for any field.
Minimum Length
OMIT IF EMPTY - Forces empty fields to be omitted.
Omit If Empty
OUTPUT FORMAT - Type of output file to create.
Choices are SDF (default, for System Data Format),
DEL (for delimited)
DB3 (for dBase III type)
PDX35 (for Paradox 3.5)
PDX40 (for Paradox 4.0)
PDX (for Paradox 4.0)
Output Format SDF
Output Format DB3
Output Format DEL
Output Format PDX35
Output Format PDX40
Output Format PDX (same as PDX40)
SURROUND WITH - Character that surrounds fields in output file (if any).
Note: This is only applicable if DEL is the output format.
Surround With "
DELIMIT WITH - Character that separates fields in output file (if any).
Note: This is only applicable if DEL is the output format.
Delimit With ,
Note: Use the \## form of the parameter to specify an ASCII character.
Here, the symbol \32 signifies a [Space].
Delimit With \32
Field commands follow.
FIELD NUMBER - designates the field that these commands will pertain to.
It must precede any field commands that are used.
Field Number 1
FIELD START - Character position to start reading data from.
In this example, no characters are skipped.
Field Start 1
FIELD LENGTH - Length of this field in the output file.
Field Length 20
FIELD NAME - If Output Format is DB3, this gives the field a name.
Field Name Text
FIELD TYPE - If Output Format is DB3, this specifies a field type.
FIELD TYPE - If Output Format is PDX35 or PDX40 or PDX, this specifies
a Paradox field type. Only Alphanumeric is supported.
Field Type C (for DB3)
Field Type A15 (for PDX, this specifies alphanumeric of length 15)
SEARCH FOR - Search for specific text in this field.
Search For Text
RESPECT CASE - Be sensitive to upper/lowercase when searching for text.
Default is Y or T.
Respect Case Y
MUST HAVE - If Y or T, any records that do NOT have the desired text
will be discarded.
Must Have N
MUST NOT HAVE - If Y or T, any records that DO have the desired text
will be discarded.
Must Not Have N
REPLACE WITH - If the text sought is found, it can be replaced with the text
specified in this command.
Replace With Text
INIT WITH - Text used to initialize field prior to working on it.
Init With Text
CONVERT TEXT - Convert field to Upper, lower or proper case.
THIS IS UPPER CASE. (all letters capitalized)
Convert Text Upper
this is lower case. (no letters capitalized)
Convert Text Lower
This Is Proper Case. (First letter capitalized)
Convert Text Proper
Note: 'Convert Text' is executed prior to any 'Search For' (and
'Replace With') commands.
JUSTIFY - Align text in a field to the extreme left or extreme right.
Justify Right
Justify Left
TRIM FRONT - Number of characters to trim from the front of a field
after it's been completely processed. This also reduces
the length a field receives.
Trim Front 10
TRIM BACK - Number of characters to trim from the end of a field after
it's been completely processed. This also reduces the
length a field receives.
Trim Front 10
The above commands only apply to ONE field. For each additional field,
specify the required 'Field Number' command, followed by the commands
you want applied to the field.
INDEX - This command can be used only when OUTPUT FORMAT specifies a
PARADOX 3.5 or PARADOX 4.0 database. When it is used in each of
the first few fields, a PRIMARY index is set up. If one or more
fields have been defined since the last INDEX command was
encountered, a SECONDARY index (automatically maintained by
PARADOX) is set up.
Index
SECONDARY INDEX - Use this to have SDF set up a secondary index on the
current field (automatically maintained by Paradox) when it
creates the PARADOX database.
Secondary Index